package day_007;

import java.util.Random;

public class demo3 {
    public static void main(String[] args) {
        //需求：确定抽奖顺序
        //其实就是数组乱序
        int arr[]={2,88,288,888,1000};
        Random r=new Random();

        for (int i = 0; i < 5; i++) {
            int num=r.nextInt(arr.length);

            int tmp=arr[num];
            arr[num]=arr[i];
            arr[i]=tmp;

        }
        for (int i = 0; i < 5; i++) {
            System.out.println(arr[i]);
        }
    }
    }

